<?php

/**
 * Created by PhpStorm.
 * User: yf
 * Date: 2018/3/3
 * Time: 下午6:48
 */
namespace App\Model\Friend;

use EasySwoole\Core\Component\Spl\SplBean;

class FriendBean extends SplBean {
	const ADD_FRIEND_PASS = 2;
	const ADD_FRIEND_ING = 1;
	const ADD_FRIEND_REFUSE = 3;
	protected $id;
	protected $fuid;
	protected $muid;
	protected $addtime;
	protected $ispass;
	
	/**
	 *
	 * @return the $ispass
	 */
	public function getIspass() {
		return $this->ispass;
	}
	
	/**
	 *
	 * @param field_type $ispass        	
	 */
	public function setIspass($ispass) {
		$this->ispass = $ispass;
	}
	
	/**
	 *
	 * @return the $id
	 */
	public function getId() {
		return $this->id;
	}
	
	/**
	 *
	 * @return the $fuid
	 */
	public function getFuid() {
		return $this->fuid;
	}
	
	/**
	 *
	 * @return the $muid
	 */
	public function getMuid() {
		return $this->muid;
	}
	
	/**
	 *
	 * @return the $addtime
	 */
	public function getAddtime() {
		return $this->addtime;
	}
	
	/**
	 *
	 * @param field_type $id        	
	 */
	public function setId($id) {
		$this->id = $id;
	}
	
	/**
	 *
	 * @param field_type $fuid        	
	 */
	public function setFuid($fuid) {
		$this->fuid = $fuid;
	}
	
	/**
	 *
	 * @param field_type $muid        	
	 */
	public function setMuid($muid) {
		$this->muid = $muid;
	}
	
	/**
	 *
	 * @param field_type $addtime        	
	 */
	public function setAddtime($addtime) {
		$this->addtime = $addtime;
	}
	function objToArray(bool $is_filter_empty): array {
		if ($is_filter_empty) {
			return $this->toArray ( null, SplBean::FILTER_NOT_EMPTY );
		} else {
			return $this->toArray ();
		}
	}
	protected function initialize(): void {
		// 默认md5是32 位，当从数据库中读出数据恢复为bean的时候，不对密码做md5
	}
}